powered by
Haversine distance matrix.
haversine.dist(x)
A a matrix of two columns. The first column is the latitude and the second the longitude.
A matrix with the haversine distances between all observations.
The function computes the haversine distance between all observations.
https://en.wikipedia.org/wiki/Haversine_formula
cosnn, dirknn
# NOT RUN { x <- rvmf(10, rnorm(3), 10) x <- euclid.inv(x) haversine.dist(x) # }
Run the code above in your browser using DataLab